var rmenu = document.getElementById("rmenu");
document.addEventListener("contextmenu", (e) => {
  e.preventDefault();
  let prevX = e.clientX;
  let prevY = e.clientY;
  if (rmenu.style.display === "") {
    document.getElementById("rmenu").style.display = "block";
    rmenu.style.top = prevY + "px";
    rmenu.style.left = prevX + "px";
  } else {
    document.getElementById("rmenu").style.display = "";
  }
});
